package com.getpebble.android.common.model;

import android.os.Parcel;
import android.os.Parcelable;
import android.os.Parcelable.Creator;
import java.util.UUID;

public class AppInfo implements Parcelable {
    public static final Creator<AppInfo> CREATOR = new Creator<AppInfo>() {
        public AppInfo createFromParcel(Parcel parcel) {
            return new AppInfo(parcel);
        }

        public AppInfo[] newArray(int i) {
            return new AppInfo[i];
        }
    };
    String[] capabilities;
    String companyName;
    private String longName;
    private String shortName;
    private String uuid;
    private float versionCode;
    private String versionLabel;

    public enum Capabilities {
        configurable
    }

    public String getLongName() {
        return this.longName;
    }

    public String getShortName() {
        return this.shortName;
    }

    public UUID getUuid() {
        if (this.uuid != null) {
            return UUID.fromString(this.uuid);
        }
        return null;
    }

    public float getVersionCode() {
        return this.versionCode;
    }

    public String getVersionLabel() {
        return this.versionLabel;
    }

    public String[] getCapabilities() {
        return this.capabilities;
    }

    public String getCompanyName() {
        return this.companyName;
    }

    public AppInfo(Parcel parcel) {
        this.longName = parcel.readString();
        this.shortName = parcel.readString();
        this.uuid = parcel.readString();
        this.versionCode = (float) parcel.readInt();
        this.versionLabel = parcel.readString();
        this.capabilities = parcel.createStringArray();
        this.companyName = parcel.readString();
    }

    public int describeContents() {
        return 0;
    }

    public void writeToParcel(Parcel parcel, int i) {
        parcel.writeString(this.longName);
        parcel.writeString(this.shortName);
        parcel.writeString(this.uuid);
        parcel.writeFloat(this.versionCode);
        parcel.writeString(this.versionLabel);
        parcel.writeStringArray(this.capabilities);
        parcel.writeString(this.companyName);
    }
}
